﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ServiceModel;

namespace ProgNetComponents.Wcf.AppUpdate
{
    /// <summary>
    /// IAppUpdateService
    /// </summary>
    [ServiceContract(CallbackContract=typeof(IAppUpdateCallback))]
    public interface IAppUpdateService
    {
        /// <summary>
        /// Gets the latest version.
        /// </summary>
        /// <returns></returns>
        [OperationContract]
        AppVersionInfo GetLatestVersion();

        /// <summary>
        /// Gets the versions after specified version.
        /// </summary>
        /// <param name="fromVersion">From version.</param>
        /// <returns></returns>
        [OperationContract]
        AppVersionInfo[] GetVersions(Version fromVersion);

        /// <summary>
        /// Registers the call back.
        /// </summary>
        [OperationContract]
        void RegisterCallBack();
    }
}
